package com.amsp.oa.oademo.service;

import com.amsp.oa.oademo.entity.EnvironmentApply;
import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.IService;

public interface EnvironmentApplyService extends IService<EnvironmentApply> {
    /**
     * 获取申请列表
     */
    IPage<EnvironmentApply> getApplyList(Page<EnvironmentApply> page, String keyword, String type, String status);

    /**
     * 提交申请
     */
    EnvironmentApply submitApply(EnvironmentApply apply);

    /**
     * 更新申请
     */
    EnvironmentApply updateApply(EnvironmentApply apply);

    /**
     * 删除申请
     */
    void deleteApply(Long id);

    /**
     * 根据申请编号查询
     */
    EnvironmentApply getApplyByNo(String applyNo);

    /**
     * 获取我的申请列表
     */
    IPage<EnvironmentApply> getMyApplies(Page<EnvironmentApply> page, String applicant, String type);

    /**
     * 处理申请
     */
    EnvironmentApply handleApply(Long id, String handler, String handleResult);

    /**
     * 取消申请
     */
    EnvironmentApply cancelApply(Long id);
} 